package tgc.edu.tms.service;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import tgc.edu.tms.custom.CommonService;
import tgc.edu.tms.entity.Student;
import tgc.edu.tms.repository.StudentRepository;

@Service
public class StudentService extends CommonService<Student, Integer>{
	@Autowired
	private StudentRepository studentDAO;

	public Student findByUsername(String username) {
		return studentDAO.findByUsername(username);
	}

	public Student findByUsernameAndName(String username, String name) {
		return studentDAO.findByUsernameAndName(username,name);
	}
	

	public Student findByPhone(String number) {
		return studentDAO.findByPhone(number);
	}


	public Student findByAddrs(String addrs) {
		return studentDAO.findByAddrs(addrs);
	}

	public Integer findgeshu(Integer id) {
		return studentDAO.findgeshu(id);
	}



}
